mengi = [["0" for x in range(0, 15)] for x in range(0, 3)]
for y in range(15):
	mengi[0][y] = y+1
	mengi[1][y] = 2*y+1
	mengi[2][y] = int(mengi[2][y-1]) + mengi[1][y]
for y in range(15):
	for x in range(3):
		print(str(mengi[x][y]) + " ", end='')
	print()
print()
